var cols = 3;
var obj = {
	cod : "",
	lTipo : null,
	msj : ""
}

function getCabecera() {
	var row = "<thead>";
	row = row + "<tr class=\"cabecera\">";
	row = row + "<th>C&oacute;digo</th>";
	row = row + "<th>Tipo</th>";
	row = row + "<th>Mensaje</th>";
	row = row + "</tr>";
	row = row + "</thead>";
	return row;
}

function getFila(data) {
	var row = "<tr class=\"fila\">";
	row = row + "<td class=\"tdelemento\" id=\"col1_" + data.id + "\">"
			+ data.nombre + "</td>";
	if (data.padre != null && data.padre != "") {
		row = row + "<td class=\"tdelemento\" id=\"col2_" + data.id
				+ "\"><p id=\"col21_" + data.id + "\">" + data.padre.nombre;
		row = row + "</p><input type=\"hidden\" id=\"col22_" + data.id
				+ "\" name=\"padre_" + id + "\" value=\"" + data.padre.id
				+ "\">";
		row = row + "</td>";
	} else {
		row = row + "<td class=\"tdelemento\" id=\"col2_" + data.id
				+ "\"><p id=\"col21_" + data.id + "\">&nbsp;";
		row = row + "</p><input type=\"hidden\" id=\"col22_" + data.id
				+ "\" name=\"padre_" + data.id + "\" value=\"" + "\">";
		row = row + "</td>"
	}
	row = row + "<td class=\"tdelemento\" id=\"col3_" + data.id + "\">" + data.orden
			+ "</td>";
	row = row + "</tr>";
	return row;
}